<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        textarea {
            display: block;
            width: 240px;
            height: 100px;
            margin: 10px 0;
        }
    </style>
</head>

<body>

    <div id="app">
        <h3>新增学员</h3>

        姓名：
        <input placeholder="请输入姓名" type="text" v-model="list.username">
        <!-- <br><br> -->
        性别:
        <input type="radio" v-model="list.gender" value="1">男
        <input type="radio" v-model="list.gender" value="2">女
        <br><br>
        年龄：
        <input placeholder="请输入年龄" type="text" v-model="list.age">
        组号：
        <input placeholder="请输入1-8组号" type="text" v-model="list.number">
        <br><br>
        期望薪资：
        <input placeholder="请输入期望薪资" type="text" v-model="list.salary">
        就业薪资
        <input placeholder="请输入就业薪资" type="text" v-model="list.reality
    ">
        <br><br>
        籍贯:
        <select v-model="list.city">
            <option value="1">北京</option>
            <option value="2">上海</option>
            <option value="3">成都</option>
            <option value="4">南京</option>
        </select>
        <select v-model="list.city1">
            <option value="1">北京</option>
            <option value="2">上海</option>
            <option value="3">成都</option>
            <option value="4">南京</option>
        </select>
        <select v-model="list.city2">
            <option value="1">北京</option>
            <option value="2">上海</option>
            <option value="3">成都</option>
            <option value="4">南京</option>
        </select>
        <br><br>
        <button class="submit" @click="onAdd()">确认</button>
        <button class="cancel" @click="onAdd2()">取消</button>
    </div>
    <script src="https://cdn.jsdelivr.net/npm/vue@2/dist/vue.js"></script>
    <script>
        const app = new Vue({
            el: '#app',
            data: {
                list:
                    {
                        username: 'tbx',
                        gender: '1',
                        age: '27',
                        number: '6',
                        salary: '16000',
                        reality: '3000',
                        city: '1',
                        city1: '2',
                        city2: '3'
                    }
            },
            methods: {
                onAdd() {
                    console.log(this.list)
                }
            },
        })
    </script>
</body>

</html>